/**
 * 
 */
package com.wolfpire.workflow.dao;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

import com.wolfpire.system.common.EasyuiPage;
import com.wolfpire.system.common.base.dao.IBaseHibernateDao;
import com.wolfpire.workflow.om.JbpmTask;

/**
 * @author lihd
 * 
 */
public interface JbpmTaskDao extends IBaseHibernateDao<JbpmTask, Long> {

	public List<JbpmTask> queryTaskListByTimeout();

	public List<JbpmTask> queryTaskListByNotTimeout();

	/**
	 * 根据任务ID获取参与者列表(参与者ID与参与者类型)
	 * 
	 * @param taskId
	 * @return
	 */
	public List<Map<String, Object>> queryParticipationListByTaskId(Long taskId);

	public List<BigDecimal> queryTaskListByProcinst(Long procinst,
			Long deploymentId, String[] userIds);

	public List<Map<String, Object>> getJbpmTaskByTaskId(Long taskId);

	public List<Map<String, Object>> getJbpmTaskByHistoryTaskId(Long taskId);

	public List<Map<String, Object>> getJbpmTaskIdByInstanceId(Long instanceId);

	public List<Map<String, Object>> queryScheduleListByTaskIdAndNodeId(
			Long taskId, Long nodeId);

	public JbpmTask findJbpmTaskByTaskId(String taskId);

	public JbpmTask findJbpmTaskByInstanceId(String InstanceId);

	public EasyuiPage<Map<String, Object>> queryAppliedList(
			EasyuiPage<Map<String, Object>> page, Integer userId,
			String userName, String status, String eventTable,
			String eventTablesql, String eventTableRelevance,
			String formTypeId, String eventTableSelectsql, String attentionType);

	public List<Map<String, Object>> queryDemandJbpmTaskByTaskName(
			String taskName);

	public List<JbpmTask> getJbpmTasks(String instanceId);
}
